package com.blb.zy_community.service.impl;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.blb.zy_community.entity.ZyCommunityInteraction;
import com.blb.zy_community.mapper.ZyCommunityInteractionMapper;
import com.blb.zy_community.service.IZyCommunityInteractionService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

/**
 * <p>
 * 社区互动表 服务实现类
 * </p>
 *
 * @author 二组
 * @since 2023-06-18
 */
@Service
public class ZyCommunityInteractionServiceImpl extends ServiceImpl<ZyCommunityInteractionMapper, ZyCommunityInteraction> implements IZyCommunityInteractionService {
    @Autowired
    private  ZyCommunityInteractionMapper communityInteractionMapper;
    @Override
    public Page<ZyCommunityInteraction> getInteractionPage(Long current, Long size, String ownerNickname, String ownerRealName, String ownerPhoneNumber) {
        return communityInteractionMapper.selectInteractionPage(new Page<>(current,size), ownerNickname,ownerRealName,ownerPhoneNumber);
    }

    @Override
    public void deleteInteraction(Long[] interactionIds) {
        communityInteractionMapper.deleteInteraction(interactionIds);
    }
}
